<?php
defined('BY_JYA') or exit('error');
$_RQ['op']=$_RQ['op']?$_RQ['op']:'basic';
$return=array();
/*******basic*******/
if($_RQ['op']=='basic'){
	if($_RQ['postdata']){
		$postdata=get_postdata();
		$this->plugin_setting('basic',$postdata);
		exi('设置成功');
	}
	$footernav = array(
			array('title'=>'首页','icon'=>'icon-shouye','color'=>'#cc99ff','action'=>'jy_yxfrom/index/','image'=>'../addons/jy_weishop/resource/images/jy_weishoparticle.png'),
			array('title'=>'项目','icon'=>'icon-viewlist','color'=>'#66cc99','action'=>'jy_yxfrom/fuwu.list/','image'=>'../addons/jy_weishop/resource/images/jy_fenleimsg.png'),
			array('title'=>'订单','icon'=>'icon-manageorder','color'=>'#66cc66','action'=>'jy_yxfrom/fuwu.order/','image'=>'../addons/jy_weishop/resource/images/jy_fenleimsg.png'),
			array('title'=>'我的','icon'=>'icon-wo1','color'=>'#FF83FA','action'=>'jy_yxfrom/member.index/','image'=>'../addons/jy_weishop/resource/images/jy_fenleimsg.png'),
	);
	$bankuai1 = array(
			array('title'=>'门窗维修','action'=>'/fuwu.list/','icon'=>'icon-shouye','img'=>'../addons/jy_yxfrom/resource/images/icon01.png'),
			array('title'=>'家电维修','action'=>'/fuwu.list/','icon'=>'icon-viewlist','img'=>'../addons/jy_yxfrom/resource/images/icon02.png'),
			array('title'=>'地板维修','action'=>'/fuwu.list/','icon'=>'icon-compass','img'=>'../addons/jy_yxfrom/resource/images/icon03.png'),
			array('title'=>'洗卫保修','action'=>'/fuwu.list/','icon'=>'icon-manageorder','img'=>'../addons/jy_yxfrom/resource/images/icon04.png'),
			array('title'=>'家政服务','action'=>'/fuwu.list/','icon'=>'icon-wo1','img'=>'../addons/jy_yxfrom/resource/images/icon05.png'),
			array('title'=>'保洁服务','action'=>'/fuwu.list/','icon'=>'icon-wo1','img'=>'../addons/jy_yxfrom/resource/images/icon06.png'),
			array('title'=>'空调清洁','action'=>'/fuwu.list/','icon'=>'icon-wo1','img'=>'../addons/jy_yxfrom/resource/images/icon07.png'),
			array('title'=>'抽油烟机','action'=>'/fuwu.list/','icon'=>'icon-wo1','img'=>'../addons/jy_yxfrom/resource/images/icon08.png'),
	);
	$hdps = array(
			array('title'=>'家电维修','icon'=>'icon-shouye','picurl'=>'../addons/jy_yxfrom/resource/images/hdp01.jpg'),
			array('title'=>'门窗维修','icon'=>'icon-viewlist','picurl'=>'../addons/jy_yxfrom/resource/images/hdp02.jpg'),
	);
	$cube =array(
		array('title'=>'首页','image'=>'../addons/jy_yxfrom/resource/images/cube01.jpg','action'=>'/index/'),
		array('title'=>'全部','image'=>'../addons/jy_yxfrom/resource/images/cube02.jpg','action'=>'/index/'),
	);
	$return['item']=$this->plugin_setting('basic');
	$return['item']['keyword']=$return['item']['keyword']?$return['item']['keyword']:'维修;空调维修';
	$return['item']['footernav']=$return['item']['footernav']?$return['item']['footernav']:$footernav;
	$return['item']['bankuai1']=$return['item']['bankuai1']?$return['item']['bankuai1']:$bankuai1;
	$return['item']['hdps']=$return['item']['hdps']?$return['item']['hdps']:$hdps;
	$return['item']['cube']=$return['item']['cube']?$return['item']['cube']:$cube;
	$htmls=array(
		'type'=>'edit',
		'desc'=>'参数设置',
		'edit_tab'=>true,
		'edits'=>array(
			array(
				'title'=>'基本信息',
				'list'=>array(
					array('type'=>'string','title'=>'网站名称','name'=>'title'),
					array('type'=>'image','title'=>'网站logo','name'=>'logo'),
					array('type'=>'text','name'=>'keyword','title'=>'热门关键词','help'=>'用英文‘;’隔开，例如：维修;空调维修'),
					array('type'=>'choose','name'=>'mid','title'=>'管理员MID','choose_title'=>'选择管理员','action'=>'core/member.get_member/'),
					//array('type'=>'radio','title'=>'是否需要先付款？','options'=>'is_dianfee','name'=>'is_dianfee','help'=>'这是在线无需付费，只需预约！'),
					array('type'=>'pcd','name'=>'pcd','title'=>'邮寄地址','help'=>''),
					array('type'=>'string','name'=>'address','title'=>'详细地址','help'=>''),
					array('type'=>'string','name'=>'username','title'=>'邮寄联系人','help'=>''),
					array('type'=>'string','name'=>'mobile','title'=>'邮寄联系电话','help'=>'','help'=>'如果这里填了，寄件人电话必须填这个。这样【顺丰快递】才能正常查到物流信息！'),
					array('type'=>'string','title'=>'分享标题','name'=>'share_title'),
					array('type'=>'image','title'=>'分享图片','name'=>'share_image'),
					array('type'=>'string','title'=>'分享描述','name'=>'share_desc'),
				)
			),
			array(
					'title'=>'界面UI配色',
					'list'=>array(
						array('type'=>'color_pool','title'=>'选择配色方案','name'=>'syscolor','help'=>''),
						array('type'=>'colorpicker','title'=>'站点颜色','name'=>'syscolor','help'=>'自定义系统颜色系，默认： #18bc9c'),
						array('type'=>'phone_tpl','name'=>'syscolor'),
					)
			),
			array(
				'title'=>'幻灯片',
					'list'=>array(
						array(
							'type'=>'array',
							'name'=>'hdps',
							'add_tip'=>'添加一个幻灯片',
								'list'=>array(
									array('type'=>'image','name'=>'picurl','title'=>'幻灯片图片'),
									array('type'=>'string','name'=>'url','title'=>'幻灯片链接'),
									
								),
								'details'=>array(
									array('type'=>'image','name'=>'picurl','title'=>'幻灯片图片','help'=>''),
									array('type'=>'link','from'=>'action','name'=>'url','title'=>'幻灯片链接'),
									
								)
						)
					)
			),
			array(
					'title'=>'欢迎幻灯片',
					'list'=>array(
								array('type'=>'switch','title'=>'开启欢迎页面','name'=>'iswelcome','help'=>'开启后，访问首页会先进入欢迎页面！'),
								array('type'=>'array','title'=>'欢迎幻灯片','name'=>'welcomehdps','add_tip'=>'添加一个欢迎幻灯片',
										'list'=>array(
											array('type'=>'string','name'=>'title','title'=>'标题'),
											array('type'=>'image','name'=>'picurl','title'=>'图片'),
											array('type'=>'string','name'=>'url','title'=>'地址'),
										),
										'details'=>array(
											array('type'=>'string','name'=>'title','title'=>'标题'),
											array('type'=>'string','name'=>'desc','title'=>'描述'),
											array('type'=>'image','name'=>'picurl','title'=>'图片','help'=>'推荐尺寸：750*900'),
											array('type'=>'link','name'=>'url','from'=>'action','title'=>'地址'),
										)
								),
					)
			),
			array(
				'title'=>'板块导航',
					'list'=>array(
									array('type'=>'array','name'=>'bankuai1','add_tip'=>'添加一个板块导航',
									'list'=>array(
										array('type'=>'string','name'=>'title','title'=>'导航名称'),
										array('type'=>'image','name'=>'img','title'=>'导航图片'),
										array('type'=>'string','name'=>'action','title'=>'导航链接'),							
									),
									'details'=>array(
										array('type'=>'string','name'=>'title','title'=>'导航名称'),
										array('type'=>'image','name'=>'img','title'=>'导航图片'),							
										array('type'=>'link','from'=>'action','name'=>'action','title'=>'导航链接'),
									)
								),
					)
			),
			array(
				'title'=>'底部导航',
					'list'=>array(
									array('type'=>'array','name'=>'footernav','add_tip'=>'添加一个底部导航',
									'list'=>array(
										array('type'=>'string','name'=>'title','title'=>'导航名称'),
										array('type'=>'icon','name'=>'icon','from'=>'jinyunicon','title'=>'导航图标'),
										array('type'=>'string','name'=>'action','title'=>'导航链接'),							
									),
									'details'=>array(
										array('type'=>'string','name'=>'title','title'=>'导航名称'),
										array('type'=>'icon','name'=>'icon','from'=>'jinyunicon','title'=>'导航图标','help'=>'图标，例如：icon-shouye'),							
										array('type'=>'link','name'=>'action','from'=>'action','title'=>'导航链接'),
									)
								),
					)
			),
			array(
					'title'=>'魔方设置',
					'list'=>array(
						array('type'=>'array','name'=>'cube','add_tip'=>'添加一个魔方',
								'list'=>array(
									array('type'=>'image','name'=>'image','title'=>'图片'),	
									array('type'=>'string','name'=>'url','title'=>'链接'),
								),
								'details'=>array(
									array('type'=>'image','name'=>'image','title'=>'图片'),
									array('type'=>'link','name'=>'url','from'=>'action','title'=>'链接'),
								)
						),
					)
			),
			array(
					'title'=>'页面开关设置',
					'list'=>array(
						//array('type'=>'switch','title'=>'关闭漂浮客服按钮','name'=>'nokefu','help'=>'这里将全局显示客服按钮（浮动页面右下角），客服指向设置：移步--设置--基础设置--联系我们（H5端客服类型，小程序端客服类型）'),
						//array('type'=>'switch','title'=>'关闭顶部搜索','name'=>'issearch'),
						array('type'=>'switch','title'=>'关闭幻灯片','name'=>'ishdps'),
						array('type'=>'switch','title'=>'关闭公告栏','name'=>'isnotice'),
						//array('type'=>'switch','title'=>'关闭轮播导航','name'=>'isswiper'),
						array('type'=>'switch','title'=>'关闭板块导航1','name'=>'isbankuai1'),
						//array('type'=>'switch','title'=>'关闭分类板块','name'=>'groups'),
						array('type'=>'switch','title'=>'关闭魔方','name'=>'iscube'),
						//array('type'=>'switch','title'=>'关闭底部菜单','name'=>'isfooternav'),
						//array('type'=>'switch','title'=>'关闭分享','name'=>'isshare'),
						array('type'=>'switch','title'=>'关闭未支付弹窗','name'=>'no_ordermodal'),
						array('type'=>'switch','title'=>'关闭弹幕','name'=>'no_tanmu'),
					)
				),
		),
	);
	$return['is_dianfee']=array('先付款才能下单','店内服务无需先付款','全部服务无需先付款');
	$return['htmls']=$htmls;
	exi($return);
}
/*******basic*******/
/*******op*******/
